<?php echo '<?xml version="1.0" encoding="UTF-8"?>' ?>

<urlset
      xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"
      xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
      xsi:schemaLocation="http://www.sitemaps.org/schemas/sitemap/0.9
            http://www.sitemaps.org/schemas/sitemap/0.9/sitemap.xsd">

<?php foreach($items as $item): ?>
    <url>
        <loc><?php echo CHtml::encode($this->createAbsoluteUrl('item/index',array('id'=>$item['id']))); ?></loc>
        <changefreq>weekly</changefreq>
        <priority>0.5</priority>
    </url>
<?php endforeach; ?>

<?php foreach($categories as $category): ?>
    <url>
        <loc><?php echo CHtml::encode($this->createAbsoluteUrl('category/index',array('id'=>$category['id']))); ?></loc>
        <changefreq>weekly</changefreq>
        <priority>0.5</priority>
    </url>
<?php endforeach; ?>

<?php foreach($manufacturers as $manufacturer): ?>
    <url>
        <loc><?php echo CHtml::encode($this->createAbsoluteUrl('manufacturer/single',array('id'=>$manufacturer['id']))); ?></loc>
        <changefreq>weekly</changefreq>
        <priority>0.5</priority>
    </url>
<?php endforeach; ?>

<?php foreach($pages as $page): ?>
    <url>
        <loc><?php echo CHtml::encode($this->createAbsoluteUrl('page/index',array('id'=>$page['id']))); ?></loc>
        <changefreq>weekly</changefreq>
        <priority>0.5</priority>
    </url>
<?php endforeach; ?>

</urlset>
